#!/bin/bash
###
 # @Version: 0.0.1
 # @Author: ider
 # @Date: 2021-08-18 12:17:52
 # @LastEditors: ider
 # @LastEditTime: 2021-08-18 20:30:45
 # @Description: manjaro 初始化安装的内容
### 

timedatectl set-ntp 1

# pacman-mirrors -c China
# pacman -Rs --noconfirm thunderbird vlc
pacman -Syyu --noconfirm
pacman -S --noconfirm docker docker-compose vim nodejs yarn typescript tmux
pacman -Scc --noconfirm

# join docker group
usermod -aG docker ider

# pypi mirror
pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/

# yarn mirror
yarn config set registry https://registry.npm.taobao.org/

# docker image mirror
cat > /etc/docker/daemon.json<< EOF
{
    "registry-mirrors": ["https://29qkc6np.mirror.aliyuncs.com"],
    "log-driver":"json-file",
    "log-opts": {"max-size":"50m", "max-file":"3"}
}
EOF

systemctl enable docker
systemctl start docker